import UserLayout from '@/components/layout/UserLayout.vue'

// 用户区域路由配置
const userRoutes = [
  {
    path: '/user',
    component: UserLayout,
    meta: { requiresAuth: true },
    children: [
      {
        path: '',
        redirect: '/user/dashboard'
      },
      {
        path: 'dashboard',
        name: 'UserDashboard',
        component: () => import('@/views/user/Dashboard.vue'),
        meta: {
          title: '用户仪表盘 - 万象鉴真',
          description: '用户个人数据概览和功能导航',
          requiresAuth: true
        }
      },
      // 个人中心路由
      {
        path: 'profile',
        name: 'UserProfile',
        component: () => import('@/views/user/Profile/Index.vue'),
        meta: {
          title: '个人中心 - 万象鉴真',
          description: '个人信息管理和设置',
          requiresAuth: true
        }
      },
      {
        path: 'profile/personal-info',
        name: 'PersonalInfo',
        component: () => import('@/views/user/Profile/PersonalInfo.vue'),
        meta: {
          title: '个人信息 - 万象鉴真',
          description: '修改个人基本信息',
          requiresAuth: true
        }
      },
      {
        path: 'profile/detection-history',
        name: 'DetectionHistory',
        component: () => import('@/views/user/Profile/DetectionHistory.vue'),
        meta: {
          title: '检测历史 - 万象鉴真',
          description: '查看历史检测记录',
          requiresAuth: true
        }
      },
      {
        path: 'profile/security-alert',
        name: 'SecurityAlert',
        component: () => import('@/views/user/Profile/SecurityAlert.vue'),
        meta: {
          title: '安全预警 - 万象鉴真',
          description: '设置安全预警和通知',
          requiresAuth: true
        }
      },
      {
        path: 'profile/feedback',
        name: 'Feedback',
        component: () => import('@/views/user/Profile/Feedback.vue'),
        meta: {
          title: '反馈建议 - 万象鉴真',
          description: '提交反馈和建议',
          requiresAuth: true
        }
      },
      // 谣言检测路由
      {
        path: 'rumor-detection',
        name: 'RumorDetection',
        component: () => import('@/views/user/RumorDetection/Index.vue'),
        meta: {
          title: '谣言检测 - 万象鉴真',
          description: '智能谣言检测系统',
          requiresAuth: true
        }
      },
      {
        path: 'rumor-detection/text',
        name: 'TextDetection',
        component: () => import('@/views/user/RumorDetection/TextDetection.vue'),
        meta: {
          title: '文本检测 - 万象鉴真',
          description: '文本内容真实性检测',
          requiresAuth: true
        }
      },
      {
        path: 'rumor-detection/image',
        name: 'ImageDetection',
        component: () => import('@/views/user/RumorDetection/ImageDetection.vue'),
        meta: {
          title: '图片检测 - 万象鉴真',
          description: '图片内容真实性检测',
          requiresAuth: true
        }
      },
      {
        path: 'rumor-detection/combined',
        name: 'CombinedAnalysis',
        component: () => import('@/views/user/RumorDetection/CombinedAnalysis.vue'),
        meta: {
          title: '综合分析 - 万象鉴真',
          description: '多模态综合分析检测',
          requiresAuth: true
        }
      },
      {
        path: 'rumor-detection/result/:id',
        name: 'DetectionResult',
        component: () => import('@/views/user/RumorDetection/DetectionResult.vue'),
        meta: {
          title: '检测结果 - 万象鉴真',
          description: '查看详细检测结果',
          requiresAuth: true
        }
      },
      // 反诈预警路由
      {
        path: 'anti-fraud',
        name: 'AntiFraud',
        component: () => import('@/views/user/AntiFraud/Index.vue'),
        meta: {
          title: '反诈预警 - 万象鉴真',
          description: '智能反诈骗预警系统',
          requiresAuth: true
        }
      },
      {
        path: 'anti-fraud/risk-assessment',
        name: 'RiskAssessment',
        component: () => import('@/views/user/AntiFraud/RiskAssessment.vue'),
        meta: {
          title: '风险评估 - 万象鉴真',
          description: '诈骗风险评估和预警',
          requiresAuth: true
        }
      },
      {
        path: 'anti-fraud/fraud-identification',
        name: 'FraudIdentification',
        component: () => import('@/views/user/AntiFraud/FraudIdentification.vue'),
        meta: {
          title: '诈骗识别 - 万象鉴真',
          description: '诈骗类型识别和分析',
          requiresAuth: true
        }
      },
      {
        path: 'anti-fraud/knowledge-base',
        name: 'FraudKnowledgeBase',
        component: () => import('@/views/user/AntiFraud/KnowledgeBase.vue'),
        meta: {
          title: '防诈知识库 - 万象鉴真',
          description: '防诈骗知识和技巧',
          requiresAuth: true
        }
      },
      {
        path: 'anti-fraud/case-analysis',
        name: 'CaseAnalysis',
        component: () => import('@/views/user/AntiFraud/CaseAnalysis.vue'),
        meta: {
          title: '案例分析 - 万象鉴真',
          description: '典型诈骗案例分析',
          requiresAuth: true
        }
      },
      // AI内容识别路由
      {
        path: 'ai-content-detection',
        name: 'AIContentDetection',
        component: () => import('@/views/user/AIContentDetection/Index.vue'),
        meta: {
          title: 'AI内容识别 - 万象鉴真',
          description: 'AI生成内容检测系统',
          requiresAuth: true
        }
      },
      {
        path: 'ai-content-detection/image',
        name: 'AIImageDetection',
        component: () => import('@/views/user/AIContentDetection/ImageDetection.vue'),
        meta: {
          title: 'AI图片检测 - 万象鉴真',
          description: 'AI生成图片内容检测',
          requiresAuth: true
        }
      },
      {
        path: 'ai-content-detection/video',
        name: 'AIVideoDetection',
        component: () => import('@/views/user/AIContentDetection/VideoDetection.vue'),
        meta: {
          title: 'AI视频检测 - 万象鉴真',
          description: 'AI生成视频内容检测',
          requiresAuth: true
        }
      },
      {
        path: 'ai-content-detection/text',
        name: 'AITextDetection',
        component: () => import('@/views/user/AIContentDetection/TextDetection.vue'),
        meta: {
          title: 'AI文本检测 - 万象鉴真',
          description: 'AI生成文本内容检测',
          requiresAuth: true
        }
      },
      {
        path: 'ai-content-detection/audio',
        name: 'AIAudioDetection',
        component: () => import('@/views/user/AIContentDetection/AudioDetection.vue'),
        meta: {
          title: 'AI音频检测 - 万象鉴真',
          description: 'AI生成音频内容检测',
          requiresAuth: true
        }
      },
      // 声纹识别路由
      {
        path: 'voiceprint-recognition',
        name: 'VoiceprintRecognition',
        component: () => import('@/views/user/VoiceprintRecognition/Index.vue'),
        meta: {
          title: '声纹识别 - 万象鉴真',
          description: '声纹识别和比对系统',
          requiresAuth: true
        }
      },
      {
        path: 'voiceprint-recognition/management',
        name: 'VoiceprintManagement',
        component: () => import('@/views/user/VoiceprintRecognition/VoiceprintManagement.vue'),
        meta: {
          title: '声纹管理 - 万象鉴真',
          description: '声纹注册和管理',
          requiresAuth: true
        }
      },
      {
        path: 'voiceprint-recognition/comparison',
        name: 'VoiceComparison',
        component: () => import('@/views/user/VoiceprintRecognition/VoiceComparison.vue'),
        meta: {
          title: '声纹比对 - 万象鉴真',
          description: '声纹比对和验证',
          requiresAuth: true
        }
      },
      {
        path: 'voiceprint-recognition/suspicious-call',
        name: 'SuspiciousCallAnalysis',
        component: () => import('@/views/user/VoiceprintRecognition/SuspiciousCallAnalysis.vue'),
        meta: {
          title: '可疑通话分析 - 万象鉴真',
          description: '可疑通话检测和分析',
          requiresAuth: true
        }
      },
      // 知识中心路由
      {
        path: 'knowledge-center',
        name: 'KnowledgeCenter',
        component: () => import('@/views/user/KnowledgeCenter/Index.vue'),
        meta: {
          title: '知识中心 - 万象鉴真',
          description: '学习反诈知识和技能',
          requiresAuth: true
        }
      },
      {
        path: 'knowledge-center/detection-technique',
        name: 'DetectionTechnique',
        component: () => import('@/views/user/KnowledgeCenter/DetectionTechnique.vue'),
        meta: {
          title: '检测技巧 - 万象鉴真',
          description: '学习检测技巧和方法',
          requiresAuth: true
        }
      },
      {
        path: 'knowledge-center/antifraud-tutorial',
        name: 'AntiFraudTutorial',
        component: () => import('@/views/user/KnowledgeCenter/AntifraudTutorial.vue'),
        meta: {
          title: '防诈教程 - 万象鉴真',
          description: '防诈骗教程和指南',
          requiresAuth: true
        }
      },
      {
        path: 'knowledge-center/case-study',
        name: 'CaseStudy',
        component: () => import('@/views/user/KnowledgeCenter/CaseStudy.vue'),
        meta: {
          title: '案例学习 - 万象鉴真',
          description: '案例学习和分析',
          requiresAuth: true
        }
      },
      {
        path: 'knowledge-center/tech-trends',
        name: 'TechTrends',
        component: () => import('@/views/user/KnowledgeCenter/TechTrends.vue'),
        meta: {
          title: '技术趋势 - 万象鉴真',
          description: '最新技术发展趋势',
          requiresAuth: true
        }
      }
    ]
  }
]

export default userRoutes 